package com.srit.system.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.srit.system.bean.User;
import com.srit.system.constant.SystemConstant;
import com.srit.system.dao.UserDao;
import com.srit.system.service.UserService;

/**
 * @author chenxiling
 *
 */
@Service
@Transactional
public class UserServiceImpl implements UserService {

	@Autowired
	private UserDao userDao;
	@Override
	public String userLogin(User user) {
		User userNew = userDao.getUserByName(user.getUserName());
		if(userNew!=null)
			return SystemConstant.SUCCESS;
		else
			return SystemConstant.FAIL;
	}
	@Override
	public String userValidate(User user) {
		// TODO Auto-generated method stub
		return null;
	}
	
	
}
